home *** CD-ROM | disk | FTP | other *** search
- LEA $7000.W,A0 source
- LEA $7100.W,A1 destination
- BSR DEPACK2
-
- DEPACK2
- LEA 4(A0),A0
- LEA (A0),A4
- MOVE.L (A0)+,D5
- ADDA.L D5,A1
- ADDA.L (A0),A0
- LEA -4(A0),A0
-
- TST.W -(A0) Test if it's a dummy.
- BPL.S L652BC NO. Valid data.
- LEA -1(A0),A0 Adjust it.
-
- L652BC MOVE.B -(A0),D0
- L652BE LSL.B #1,D0
- BNE.S L652C6
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L652C6 BCC.S L65322 Go do the REPEATS.
-
- CLR.W D1 Clear size count.
- LSL.B #1,D0
- BNE.S L652D2
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L652D2 BCC.S L65316 If ZERO then its a 1 byte repeat
-
- LEA L6530E(PC),A3 Lower table? BIT sizes.
- MOVEQ #3,D3 Initial index.
- L652DA CLR.W D1 Clear size count.
- MOVE.B 0(A3,D3.W),D2 Get the BITsize.
- EXT.W D2 Clear the crap.
- MOVEQ #-1,D4 Set all the bits.
- LSL.W D2,D4 Fill with X zero bits.
- NOT.W D4 Invert the BITS.
- SUBQ.W #1,D2 Adjust bit size.
-
- L652EA LSL.B #1,D0
- BNE.S L652F2
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L652F2 ROXL.W #1,D1 Collect the size.
- DBF D2,L652EA
-
- TST.W D3 ??? No zeroes in the table.
- BEQ.S L65302
- CMP.W D1,D4
- DBNE D3,L652DA
- L65302 MOVE.B 4(A3,D3.W),D2 Upper table. ADJUSTMENTS.
- EXT.W D2 Clear crap.
- ADD.W D2,D1 Adjust JUNK's count size.
- BRA.s L65316
-
- L6530E DC.B $A,3,2,2,$E,7,4,1
-
- L65316 MOVE.B -(A0),-(A1) Transfer BYTES of junk.
- DBF D1,L65316
-
- L65322 MOVEA.L A4,A3
- ADDQ.L #8,A3
- CMPA.L A3,A0
- BLE gohome
- LEA L65368(PC),A3 Little table.
- MOVEQ #3,D2
- L65332 LSL.B #1,D0
- BNE.S L6533A
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L6533A BCC.S L65340
- DBF D2,L65332
-
- L65340 CLR.W D1
- ADDQ.W #1,D2
- MOVE.B 0(A3,D2.W),D3 Get the BIT size.
- BEQ.S L6535C If ZERO no more bit to collect.
- EXT.W D3 Clear the crap.
- SUBQ.W #1,D3 Adjust for looping
-
- L6534E LSL.B #1,D0
- BNE.S L65356
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L65356 ROXL.W #1,D1
- DBF D3,L6534E
-
- L6535C MOVE.B 5(A3,D2.W),D3 Get any ADJUSTMENTS.
- EXT.W D3
- ADD.W D3,D1
- BRA.s L65372 Go to normal REPEAT routine.
-
- L65368 DC.B $A,2,1,0,0,$A,6,4 Little table.
- DC.B 3,2
-
- L65372 CMPI.W #2,D1 2byte repeat.
- BEQ.S rep Yeh. Use A3's small table.
- LEA L653AC(PC),A3 ELSE use the big table.
- MOVEQ #1,D3 Only two bits to collect.
- L6537E LSL.B #1,D0
- BNE.S L65386
- MOVE.B -(A0),D0
- ROXL.B #1,D0
-
- L65386 BCC.S L6538C If first bit zero then leave
- DBF D3,L6537E
- L6538C ADDQ.W #1,D3 Adjust index into the table.
- CLR.W D2 UGH!!
- MOVE.B 0(A3,D3.W),D4 Fetch offset's bitsize.
- EXT.W D4 Clear the crap.
-
- L65396 LSL.B #1,D0
- BNE.S L6539E
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L6539E ROXL.W #1,D2 Collect offset.
- DBF D4,L65396
- LSL.W #1,D3 Align with upper table.
- ADD.W 4(A3,D3.W),D2 Add the adjustment to the offset.
- BRA.S L653DC Go to MAIN repeat routine.
-
- L653AC DC.B $B,4,7,0,1,$20 Offset bit sizes.
- DC.B 0,0,0,$20,0,0 Adjustments to the offsets.
-
- rep CLR.W D2 Clear offset register.
- MOVEQ #5,D3 SMALL 6bit offset
- CLR.W D4 Set the ADJUSTER.
- LSL.B #1,D0
- BNE.S L653C6
- MOVE.B -(A0),D0
- ROXL.B #1,D0
- L653C6 BCC.S L653CC If CLEAR then small offset.
- MOVEQ #8,D3 LARGE 9bit offset.
- MOVEQ #$40,D4 Set the ADJUSTER.
-
- L653CC LSL.B #1,D0
- BNE.S L653D4
- MOVE.B -(A0),D0 Reload the data register.
- ROXL.B #1,D0 and shift first bit.
- L653D4 ROXL.W #1,D2 Collect the offset.
- DBF D3,L653CC
-
- ADD.W D4,D2 Add any ADJUSTER to offset.
- L653DC LEA 0(A1,D2.W),A2 Calc address of repeated string.
- EXT.L D1 Clear the shit in the LENGTH.
- ADDA.L D1,A2 LENGTH + address = string end.
- SUBQ.W #1,D1 Adust LENGTH for looping.
- L653E6 MOVE.B -(A2),-(A1) Transfer the bytes.
- DBF D1,L653E6
- BRA L652BE
- gohome RTS
-
-